<%@page import="RssEasy.Core.CookieHelper"%>
<%@page import="RssEasy.Core.Encrypt"%>
<%@page import="Controller.SendSms"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%
    String phone = request.getParameter("phone");
    String num = "";
    for (int i = 0; i < 6; i++) {
        num = num + Math.round(Math.random() * 9);
    }
    Cookie cookie = new Cookie("key",Encrypt.Md532(num));
    cookie.setMaxAge(60);
    cookie.setPath("/");
    response.addCookie(cookie);
    SendSms send = new SendSms();
    send.telphone = "15011046599";
    send.matter = "您的验证码是：" + num + "";
    send.send();
%>
